<%@ taglib prefix="s" uri="/struts-tags"%>
<%@ taglib prefix="tiles" uri="http://tiles.apache.org/tags-tiles"%>

<div class="list" id="commentAside">
	<p>
		<s:text name="aside.commentManagement" />
	</p>
	<ul>
		<!-- common actions -->
		<li><s:a href="showAllComments?">
				<s:text name="aside.allComments" />
			</s:a></li>
		<li><s:a href="writeNewComment?">
				<s:text name="aside.writeComment" />
			</s:a></li>

		<s:if test="#session.user.role > 1">
			<!-- administrator-only actions -->
			<li><s:a href="deleteComment?">
					<s:text name="aside.deleteComment" />
				</s:a></li>

			<li><s:a href="modifyComment?">
					<s:text name="aside.modifyComment" />
				</s:a></li>
		</s:if>

		<s:else>
			<!-- user-only actions -->
			<li><s:a href="deleteUnpublishedComment?">
					<s:text name="aside.deleteUnpublishedComment" />
				</s:a></li>
			<li><s:a href="modifyPersonalComment?">
					<s:text name="aside.modifyPersonalComment" />
				</s:a></li>
		</s:else>
	</ul>
</div>